package cn.edu.fzu.homemaking.domain.enums;

/**
 * @author yifan
 * @date 2023/4/7
 */
public enum SysCompanyUserTypeEnum {
    ADMIN(0, "公司管理员"),

    STAFF(1, "员工");

    private final int    value;

    private final String desc;

    SysCompanyUserTypeEnum(int value, String desc) {
        this.value = value;
        this.desc = desc;
    }


    public int getValue() {
        return value;
    }


    public String getDesc() {
        return desc;
    }


    public static SysCompanyUserTypeEnum parse(int value) {
        switch (value) {
            case 0:
                return ADMIN;
            case 1:
                return STAFF;
            default:
                return null;
        }
    }

}
